﻿using System.ComponentModel.DataAnnotations;

namespace BCDto.Common.News.NewsContent
{
    /// <summary>
    /// 新闻内容
    /// </summary>
    public class NewsContentRequestDto
    {
        /// <summary>
        /// 标题
        /// </summary>
        [Display(Name = "标题")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public string Title { get; set; }
        /// <summary>
        /// 短标题
        /// </summary>
        [Display(Name = "短标题")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public string SubTitle { get; set; }
        /// <summary>
        /// 内容
        /// </summary>
        [Display(Name = "内容")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public string Content { get; set; }
        /// <summary>
        /// 内容分类Id
        /// </summary>
        [Display(Name = "内容分类Id")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public int ContentCategoryId { get; set; }
        /// <summary>
        /// 浏览次数
        /// </summary>
        [Display(Name = "浏览次数")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public int ViewsCount { get; set; }
        /// <summary>
        /// 关键字
        /// </summary>
        [Display(Name = "关键字")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public string KeyWord { get; set; }
        /// <summary>
        /// 内容摘要
        /// </summary>
        [Display(Name = "内容摘要")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public string Summary { get; set; }
        /// <summary>
        /// 图片地址
        /// </summary>
        [Display(Name = "图片地址")]
        public string ImageUrl { get; set; }
        /// <summary>
        /// 链接地址
        /// </summary>
        [Display(Name = "链接地址")]
        public string Link { get; set; }

        /// <summary>
        /// 是否可评论
        /// </summary>
        [Display(Name = "是否可评论")]
        [Required(ErrorMessage = "{0} 不能为空")]
        public bool IsComment { get; set; }
    }
}
